package net.qiqbframework.common.lock;

public interface TopicLock extends AutoCloseable {


    @Override
    default void close() {
        release();
    }

    boolean tryLock();

    /**
     * 是否获取锁
     *
     * @return
     */
    boolean lock();

    void release();


    boolean isHeld();

    String getTopicName();
}
